<%@ page language="java" pageEncoding="UTF-8"%>
<%@ taglib prefix="s" uri="/WEB-INF/struts-tags.tld"%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<title>欢迎访问产品运营互动中心！</title>
<link rel="stylesheet" href="<s:url value="/css/style_new.css"/>">
<link href="<s:url value="/images/08_ccxxzx.css"/>" rel="stylesheet" type="text/css" />
<script type="text/javascript" src="<s:url value="/script/sysOper.js"/>"></script>
<script type="text/javascript" src="<s:url value="/script/selfResize.js"/>"></script>
<script type="text/javascript" src="<s:url value="/components/datepicker/WdatePicker.js"/>"></script>
<script>
function show(url){
	window.open(url);
}
function initLoad(){
	f_iframeResize();
}
window.onload = initLoad;
</script>
</head>
<body bgcolor="#FFFFFF" leftmargin="0" topmargin="0">
<table width="980" border="0" cellspacing="0" cellpadding="0" align="center">
		<tr>
			<td>
			<table width="100%" border="0" cellpadding="0" cellspacing="0"
				background="<s:url value="/images/new/gxzl_index_2.gif"/>">
				<tr>
					<td width="20" height="32">&nbsp;</td>
					<td width="20"><img
						src="<s:url value="/images/new/dq_dot.gif"/>" width="15"
						height="12" /></td>
					<td>当前位置：业务需求交互单-合并需求单</td>

				</tr>
			</table>
			</td>
		</tr>
	<tr>
		<td background="<s:url value="/images/home_4a.gif"/>">
		<table width="100%" border="0" cellspacing="0" cellpadding="0" align="center" bgcolor="#FFFFFF">
			<tr>
				<td width="20%" valign="top">
				<table width="100%" height="400"  border="0" cellspacing="0" cellpadding="0"
					align="center" bgcolor="#FFFFFF">
					<tr>
						<td valign="top" align="center">
						<s:form action="auditProdAdvReq.action" namespace="/bpm" method="post" enctype="multipart/form-data">
							<input type="hidden" name="refIds" value="${refIds}">
							<input type="hidden" name="flag" value="">
							<input type="hidden" name="prodAdvReq.id" value="">
							<input type="hidden" name="prodAdvReq.begin" value="${prodAdvReq.begin}">
							<input type="hidden" name="prodAdvReq.end" value="${prodAdvReq.end}">
							<input type="hidden" name="prodAdvReq.opType" value="${prodAdvReq.opType}">
							<input type="hidden" name="prodAdvReq.relaReq" value="${prodAdvReq.relaReq}">
							<input type="hidden" name="prodAdvReq.tranStatus" value="${prodAdvReq.tranStatus}">
							<input type="hidden" name="prodAdvReq.tranReason" value="${prodAdvReq.tranReason}">
							
							
							<table width="98%" align="center" border="0" cellspacing="0" cellpadding="0">
								<br/>
								<tr>
									<td height="5">
										<table width="100%" border="0" cellspacing="0" cellpadding="0">
											<tr>
												<td width="5" height="5"><img src="<s:url value="/images/cphdzx_tab1.gif"/>" width="5" height="5" /></td>
												<td class="tdborderup"><img src="<s:url value="/images/spacer.gif"/>" width="1" height="1" /></td>
												<td width="5"><img src="<s:url value="/images/cphdzx_tab2.gif"/>" width="5" height="5" /></td>
											</tr>
										</table>
									</td>
								</tr>
								<tr>
									<td  class="tdborderleftright">
									<TABLE width="98%" cellSpacing=1 cellPadding=0 align="center">
										<TR height=30>
											<TD align=left width="10%"><input type="submit" name="Submit" value="合 并" onclick="return check();"><input type="button"
												value="返 回" onClick="window.history.back();">
											</TD>
										</TR>
									</table><br>
									<s:if test='%{prodAdvReq.reqCode!=null}'>
										&nbsp;&nbsp;&nbsp;需求单号：${prodAdvReq.reqCode}<input type="hidden" name="prodAdvReq.reqCode" value="${prodAdvReq.reqCode}">
									</s:if>
									<table width="98%" border="0" cellspacing="0" cellpadding="7"
										align="center" class=tablecolor2>
										
                  <tr>
                    <td bgcolor="D6E3FA"><div align="right" class="STYLE2"><font color="red">*</font>需求名称：</div></td>
                    <td colspan="3">
											<s:textfield name="prodAdvReq.name" theme="css_xhtml" size="110" />
                    </td>
                  </tr>
                  <tr>
                    <td bgcolor="D6E3FA"><div align="right" class="STYLE2">期望完成时间：</div></td>
                    <td>
												<input type="text" name="advanTime" size="14" class="Wdate" onFocus="new WdatePicker(this)">
												<s:date name="prodAdvReq.advanTime" format="yyyy年MM月dd日"/>
												<input name="prodAdvReq.advanTime" type="hidden" value="${prodAdvReq.advanTime}">
                    </td>
                    <td bgcolor="D6E3FA" width="140"><div align="right" class="STYLE2">提出时间：</div></td>
                    <td width="268">
												${prodAdvReq.begin}
                    </td>
                  </tr>
                  <tr>
                    <td bgcolor="D6E3FA" width="140"><div align="right" class="STYLE2">产品经理：</div></td>
                    <td width="268">
											<input type="hidden" name="prodAdvReq.prodPerson.id" value="${prodAdvReq.prodPerson.id}">
											<input type="text" name="prodPerson" readonly value="${prodAdvReq.prodPerson.name}">
                    	<input type="button" name="人员选择" value="人员选择" class="buttoncom4" onclick="selectPersonsBy()" />
                    </td>
                    <td bgcolor="D6E3FA"><div align="right" class="STYLE2">产品部门：</div></td>
                    <td>
                    	<input type="text" name="prodDept" value="${prodAdvReq.prodDept.name}" 
                    	 class="input_nob" size="40" readonly>
                    	<input type="hidden" name="prodAdvReq.prodDept.id" value="${prodAdvReq.prodDept.id}" >
                    </td>
                  </tr>
                  <tr>
                    <td bgcolor="D6E3FA" width="140"><div align="right" class="STYLE2">需求类别：</div></td>
                    <td width="268">
					<s:select name="prodAdvReq.type.id"
						list="types" listKey="id" listValue="name"
						theme="css_xhtml" />
	
                    </td>
                    <td bgcolor="D6E3FA" width="140"><div align="right" class="STYLE2">重要性：</div></td>
                    <td width="268">
						<s:select name="prodAdvReq.importance.id"
							list="importances" listKey="id" listValue="name"
							theme="css_xhtml" />
                    </td>
                  </tr>
                  
                  
                  <!--tr>
                    <td bgcolor="D6E3FA" width="140"><div align="right" class="STYLE2">发起时间：</div></td>
                    <td width="268">
												${prodAdvReq.begin}
                    </td>
                    <td bgcolor="D6E3FA" width="140">
                    </td>
                    <td width="268">
                    </td>
                  </tr-->
                  <tr>
                    <td bgcolor="D6E3FA"><div align="right" class="STYLE2"><font color="red">*</font>优化内容：</div></td>
                    <td colspan="3">
											<s:textarea name="prodAdvReq.content" theme="css_xhtml" cols="96" rows="4" />
					  				</td>
                  </tr>
                  <tr>
                    <td bgcolor="D6E3FA"><div align="right" class="STYLE2">备&nbsp;&nbsp;&nbsp;&nbsp;注：</div></td>
                    <td colspan="3">
											<s:textarea name="prodAdvReq.remark" theme="css_xhtml" cols="96" rows="4" />
					  				</td>
                  </tr>
                  
                  
                  <tr> 
                    <td width="111" bgcolor="D6E3FA"> <div align="right" class="STYLE2">附&nbsp;&nbsp;&nbsp;&nbsp;件：</div></td>
                    <td colspan="3">
											<table width="90%" border="0" class=tablecolor2>
												<tr>
													<td width="60%" align="center" bgcolor="D6E3FA">附件名称</td>
													<td width="18%" align="center" bgcolor="D6E3FA">附件类型</td>
													<!--td width="18%" align="center" bgcolor="D6E3FA">删除</td-->
												</tr>
												<s:iterator id="reqDocu" value="reqDocus">
												<input type="hidden" name="attachIDs" value="<s:property value="id" />"/>
												<tr>
													<td>
														<a href="<s:url value="/bpm/showDocu.action?reqDocu.id="/><s:property value="id" />"
															target="_blank">
															<s:property value="fullName" />
														</a>
													</td>
													<td align="center">
														<s:property value="docTypeName" />
													</td>
												</tr>
												</s:iterator>
											</table>
											<br>
                      </div></td>
                  </tr>
                  <tr>
                    <td bgcolor="D6E3FA"><div align="right" class="STYLE2"><font color="red">*</font>被合并需求单：</div></td>
                    <td colspan="3">
					 							<table width="100%" border="0" class=tablecolor2>
                          <tr>
                            <td align="center" bgcolor="D6E3FA" width="6%">序号</td>
                            <td align="center" bgcolor="D6E3FA" width="19%">名称</td>
                            <td align="center" bgcolor="D6E3FA" width="18%">发起人</td>
                            <td align="center" bgcolor="D6E3FA" width="*%">优化内容</td>
                          </tr>
											<s:iterator value="prodAdvReqs" status="st">
                          <tr>
                            <td align="center"><s:property value="#st.getIndex()+1"/></td>
                            <td align="center"><s:property value="name"/></td>
                            <td align="center"><s:property value="startPerson.name"/></td>
                            <td align="center"><s:property value="content"/></td>
                          </tr>
                    	</s:iterator>
                        </table>
					  				</td>
                  </tr>
									
                </table>
										
									</td>
								</tr>
								<tr>
									<td height="5">
										<table width="100%" border="0" cellspacing="0" cellpadding="0">
											<tr>
												<td width="5" height="5"><img src="<s:url value="/images/cphdzx_tab3.gif"/>" width="5" height="5" /></td>
												<td class="tdborderbottom"><img src="<s:url value="/images/spacer.gif"/>" width="1" height="1" /></td>
												<td width="5"><img src="<s:url value="/images/cphdzx_tab4.gif"/>" width="5" height="5" /></td>
											</tr>
										</table>
									</td>
								</tr>
							</table></td>
					</tr>
				</table>
				</s:form> 
</body>
<script>
function check(){
	if(document.all['prodAdvReq.name'].value==""){
		alert("需求名称不能为空，请填写！");
		return false;
	}
	if(document.all['prodAdvReq.content'].value==""){
		alert("需求内容不能为空，请填写！");
		return false;
	}
	var time2=document.all['advanTime'].value;
	if(time2.length==10){
		document.all['prodAdvReq.advanTime'].value=document.all['advanTime'].value+" 00:00:00";
	}
	return true;
}
function selectStartPerson(){
    var url="<s:url value='/' escapeAmp='false'/>"+"organ/toOrganTree.action?type=&path=toPersonTree&module=radio&date=<%=System.currentTimeMillis()%>";	 
    var returnData=window.showModalDialog(url,window,"status:no;dialogWidth:650px;dialogHeight:600px;scroll:yes;");
	 if(returnData){
	 	document.forms[0]["startPerson"].value=returnData[1];
	 	document.forms[0]["prodAdvReq.startPerson.id"].value=returnData[0];
	 }
}
function selectPersonsBy(){
	var url="<s:url value='/' escapeAmp='false'/>"+"organ/selectPerson.action";	
	var returnData=window.showModalDialog(url,window,"status:no;dialogWidth:960px;dialogHeight:640px;scroll:yes;");
	if(returnData){
		document.all['prodPerson'].value=returnData[1];
		document.all['prodAdvReq.prodPerson.id'].value=returnData[0];
		document.all['prodDept'].value="";
		document.all['prodAdvReq.prodDept.id'].value="";
	}
}
function save(){
	/*
	var time2=document.all['advanTime'].value;
	if(time2.length==10){
		document.all['prodAdvReq.advanTime'].value=document.all['advanTime'].value+" 00:00:00";
	}*/
}

function isNullSel(obj){
	if(obj&&obj.options&&obj.options.selectedIndex!=-1&&obj.options[obj.options.selectedIndex].value!=""){
		return false;
	}
	return true;
}

</script>
</html>